package com.xjd.edu.admin.service.sys.remote;

import com.xjd.edu.admin.service.RemoteLogService;
import com.xjd.edu.admin.service.sys.ISysLogininforService;
import com.xjd.edu.admin.service.sys.ISysOperLogService;
import com.xjd.edu.common.admin.domain.SysLogininfor;
import com.xjd.edu.common.admin.domain.SysOperLog;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@RequestMapping("/com.xjd.edu.admin.service.remoteLogService")
public class RemoteSysLogininforServiceImpl implements RemoteLogService {

    @Autowired
    private ISysLogininforService logininforService;

    @Autowired
    private ISysOperLogService operLogService;

    @Override
    public void saveLog(SysOperLog sysOperLog, String source) throws Exception {
        operLogService.insertOperlog(sysOperLog);
    }

    @Override
    public void saveLogininfor(SysLogininfor sysLogininfor, String source) {
        logininforService.insertLogininfor(sysLogininfor);
    }
}
